//
//  LBToneCurveFilter.h
//  OpenGLGame
//
//  Created by Nguyen Cong Huy on 3/25/13.
//  Copyright (c) 2013 UIT. All rights reserved.
//

#ifndef OpenGLGame_LBToneCurveFilter_h
#define OpenGLGame_LBToneCurveFilter_h

#include "LBFilter.h"
#include <list>
using namespace std;

class LBTexture;
class LBCurveAcvFile;

class LBToneCurveFilter : public LBFilter{
    
    LBCurveAcvFile* avcFile;
    GLuint curveTextureUniform;
    GLuint toneCurveTexture;
    
    list<LBPoint2> preparedSplineCurve(list<LBPoint2> pointControl);
public:
    
    list<LBPoint2> rgbCompositeCurve;
    list<LBPoint2> redCurve;
    list<LBPoint2> greenCurve;
    list<LBPoint2> blueCurve;
    
    LBToneCurveFilter();
    void setCurveImageData(unsigned char* toneCurveByteArray);
    virtual void renderTexture(int x, int y, float scaleX, float scaleY);
};

#endif
